package com.ws.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.util.Date;

@TableName("shop_goods")
@Data
public class Goods {

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    private String name;

    private Long goodsTypeId;

    @TableField(exist = false)
    private String goodsTypeName;

    private Double price;

    private Integer discount;

    private String description;

    private String remark;

    private Integer count;

    private String logo;

    private String pics;

    private Integer isOnSale;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date insertTime;

    private Integer saleCount;

}
